package cn.com.first;

import org.springframework.context.annotation.AnnotationConfigApplicationContext;
import org.springframework.context.annotation.ComponentScan;

@ComponentScan("cn.com.first")
public class SpringRegister {
	public static void main(String[] args) {
		AnnotationConfigApplicationContext ac= new AnnotationConfigApplicationContext(SpringRegister.class);
		User user =ac.getBean(User.class);
		System.out.println(user.toString());

	}
}

